import pymongo
import redis

mongo_client = pymongo.MongoClient(
    "mongodb://rwuser:Gr#54WE24KL!dfjh5!!lkfg874@localhost:27017/bigdata?authSource=admin&directConnection=true"
)
mongo_db = mongo_client["bigdata"]

# mysql_conn = pymysql.connect(
#     host=envs.MYSQL_HOST,
#     port=envs.MYSQL_PORT,
#     user=envs.MYSQL_USER,
#     password=envs.MYSQL_PASSWORD,
#     database=envs.MYSQL_DB,
#     charset="utf8mb4",
#     cursorclass=pymysql.cursors.DictCursor,
# )


# r = redis.Redis(
#     host=envs.REDIS_HOST,
#     port=envs.REDIS_PORT,
#     db=envs.REDIS_DB,
#     password=envs.REDIS_PASSWORD,
# )


def get_redis_conn():
    return redis.Redis(
        host="172.25.126.68",
        port=7885,
        db=0,
        password="S8!fhh983LKDsSfg6#!lldf09H",
    )


# obs_client = ObsClient(
#     access_key_id=envs.OBS_ACCESS_KEY,
#     secret_access_key=envs.OBS_SECRET_KEY,
#     server=envs.OBS_SERVER,
# )
